import request from "@/utils/request";
// 知识库类目-查询列表
export function getCategoryList(data) {
  return request({
    url: `/manager/knowledge/category/list`,
    method: "get",
    params: data,
  });
}
// 知识库类目-获取详情
export function getCategory(id) {
  return request({
    url: `/manager/knowledge/category/${id}`,
    method: "get",
  });
}
// 知识库类目-新增
export function postCategory(data) {
  return request({
    url: `/manager/knowledge/category`,
    method: "post",
    data: data,
  });
}
// 知识库类目-修改
export function putCategory(data) {
  return request({
    url: `/manager/knowledge/category`,
    method: "put",
    data: data,
  });
}
// 知识库类目排序
export function sortCategory(data) {
  return request({
    url: `/manager/knowledge/category/sort`,
    method: "put",
    data: data,
  });
}
// 知识库类目-删除
export function deleteCategory(categoryId) {
  return request({
    url: `/manager/knowledge/category/${categoryId}`,
    method: "delete",
  });
}
